const express=require('express');
const app=express();
app.listen(8080);
const usertRouter=require('./routes/user.js');
//
app.use(express.urlencoded({
 extended:false
}));

app.use('/v1/users',usertRouter);
//
app.use((err,req,res,next)=>{
//
console.log(err);
//
res.status(500).send({code:500,msg:'服务器端错误'});
});